#include <cppunit/extensions/TestFactoryRegistry.h>
#include <cppunit/ui/text/TestRunner.h>

int main(int argc, char* argv[]) {
	using namespace CppUnit;

	TextUi::TestRunner runner;
	TestFactoryRegistry& registry = TestFactoryRegistry::getRegistry();
	Test* testToRun = registry.makeTest(); 

	if(argc > 1){
		testToRun = testToRun->findTest(argv[1]);
	}

	runner.addTest(testToRun);
	bool rv = runner.run();
	
	return !rv;
}

